/*
 * 版权所有(c)  1952110078@qq.com  2022 - 2022
 */

package com.ldc.commonlibs.common;

import android.app.Application;

/**
 * @author liudc
 * @since 2022/7/17 19:56
 */
public class ComponentContext {

    private Application application;
    public Application getApplication() {
        return application;
    }

    public void setApplication(Application application) {
        this.application = application;
    }

    private static class Holder {
        private static final ComponentContext instance = new ComponentContext();
    }

    public static ComponentContext getInstance() {
        return Holder.instance;
    }

    public static void initContext(Application application) {
        ComponentContext.getInstance().setApplication(application);
    }
}
